<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
<head>
<title>�Ƽ���Ŀ�걨ϵͳ</title>
<meta http-equiv="content-type" content="text/html; charset=GB2312" />
<meta name="description" content="Your website description goes here" />
<meta name="keywords" content="your,keywords,goes,here" />
<link rel="stylesheet" href="../css/andreas08(blue).css" type="text/css" media="screen,projection" />
<script type="text/javascript" src="../js/acesys.js"></script>
</head>

<body>
<div id="container" >

<div id="header";>
</div>

<div id="navigation">
<ul>
<li class="selected"></li>
<li><a href="../index.html">��ҳ</a></li>
<li><a href="../jieshao.html">ϵͳ����</a></li>
<li><a href="../zhinan.html">��ָ��</a></li>
<li><a href="../login.html">��Ŀ�걨</a></li>
<li><a href="../lianxi.html">��ϵ����</a></li>
<li></li>
</ul>
</div>

</div>
<div id="container" >
  <div id="content2">
    <table width="100%" height="41"  border="0" align="center" cellpadding="0" cellspacing="0">
    <tr>
      <td width="15" height="18" align="left" valign="top"><div align="left"></div></td>
      <td width="385" align="left" valign="bottom" class="12">&nbsp;</td>
    </tr>
    <tr>
      <td height="4" colspan="2" align="left" valign="bottom"></td>
    </tr>
    <tr>
      <td height="15" align="left" valign="top">&nbsp;</td>
      <td height="15" align="left" valign="top" class="12"><table width="100%" height="20" border="0" cellpadding="0" cellspacing="0">
        <tr>
          <td height="20"><div class="right_proaducts">�ҵ�λ��&gt;&gt;�Ƽ���Ŀ�걨&gt;����û�<br />
                  <br />
            </div>
<!--              <form action="../admin/admin_index.html" method="post" id="form">-->
                <DIV class=padding>
                <DIV id=middlebody>
                <table cellspacing="0" cellpadding="0" width="100%" border="0">
                  <tbody>
                   <tr>
	                <td><div align="left">|&nbsp;&nbsp;��ӭ,admin&nbsp;&nbsp;|&nbsp;&nbsp;
	                   <a  class="table_t"  href="../index.html">ע��</a>&nbsp;&nbsp;|&nbsp;&nbsp;
	                   <a href="javascript:history.go(-1)">����</a>&nbsp;&nbsp;|</div></td>
                      <td><div align="center"><a  href="../admin/showusers.html">��¼�û�����</a></div></td>
                      <td><div align="center"><a  href="../admin/showexperts.html">ר����Ϣ����</a></div></td>
                      <td height="50"><div align="center"><a  href="../admin/showunits.html">��λ��Ϣ����</a></div></td>
                      <td><div align="center"><a  href="../admin/showprojectCategorys.html">��Ŀ����</a></div></td>
                    </tr>
                  </tbody>
                </table>
                <table id="app" width="300" border="0" align="center" cellpadding="0" cellspacing="1" class="mars">
                  <tbody>
                    <tr bgcolor="#fba661" height="30">
                      <td width="102" height="20" bgcolor="#f3f3f3"><div align="center">�û���</div></td>
                      <td height="20" colspan="2" align="left" bgcolor="#f3f3f3"><div align="left">
                          <input type="text" name="username" v-model="user.username"/>
                      </div></td>
                    </tr>
                    <tr bgcolor="#e4f1fe">
                      <td height="20" bgcolor="#f3f3f3"><div align="center">Ȩ����</div></td>
                      <td height="20" colspan="2" align="left" bgcolor="#f3f3f3"><div align="left">
                          <select name="select" size="1" v-model="user.gid">
                            <option value="2">ר��</option>
                            <option value="3">��λ</option>
                          </select>
                      </div></td>
                    </tr>
                    <tr bgcolor="#e4f1fe">
                      <td height="30" bgcolor="#f3f3f3">&nbsp;</td>
                      <td width="60" height="30" align="left" bgcolor="#f3f3f3">
<!--					  <input type="submit" name="Submit" value="�ύ" onclick="return checkUser(form)"/>-->
                        <button @click="addUser()">�ύ</button>
                      </td>
                      <td width="134" height="30" align="left" bgcolor="#f3f3f3">
					  <input type="reset" name="Submit2" value="ȡ��" /></td>
                    </tr>
                  </tbody>
                </table>
                <div></div>
<!--              </form>-->
          </td>
        </tr>
      </table>
        <br/>
          <div class="table_wz"></div></td>
    </tr>
  </table>
</div>
</div>
<div id="container" >
  <div id="footer">
<p><a href="http://www.ascenttech.com.cn/" target="_blank">��Ȩ���У�������˼������Ƽ����޹�˾ &copy;2004-2008|��ICP��05005681</a></p>
</div>

</div>
</body>
</html>
<!--����vue-->
<script src="../js/vue.js"></script>
<!--����axios-->
<script src="../js/axios-0.18.0.js"></script>
<!--����element-ui-->
<script src="../element-ui/lib/index.js"></script>
<link rel="stylesheet" href="../element-ui/lib/theme-chalk/index.css">
<script>
    new Vue({
        el: '#app',
        data: {
            user: {
                 gid: "2",
                 username: "",
                 password: "1234"
            },
        },
        methods: {
           addUser(){
               axios.post("/users",this.user).then((res)=>{
                   if (res.data.code===20011){
                       this.$message.success("��ӳɹ���");
                   }
                   if (res.data.code==20010){
                       this.$message.error("���ʧ�ܣ�");
                   }
               }).finally(()=>{
                   //1�����תҳ��
                   setTimeout(function () {
                       location.href="http://localhost/admin/showusers.html";
                   },1000);
               })
           }
        },

    })
</script>